﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using XiaoYuStock.Model.Models;
namespace XiaoYuStock.Model.Entities
{
   public  class TradeDataModel 
    {

        public int Id { get; set; }

        public string ShareCode { get; set; }
        public DateTime TradeTime { get; set; }

        public int TradedState { get; set; }
        public decimal TradeAmount { get; set; }
       public string ShareName { get; set; }

       public string TradeStatusDes {
           get {
               if (this.TradedState == (int)TradeStatus.Buy)
               {
                   return "买";
               }else if(this.TradedState == (int)TradeStatus.Sell)
               {
                   return "卖";
               }
               return string.Empty;
           }
       }

       public int TradeCount { get; set; }

       public decimal MaxPrice { get; set; }
       public decimal MinPrice { get; set; }

       public decimal OpenPrice { get; set; }
       public decimal ClosePrice { get; set; }

       public string ShareAccount { get; set; }
    }
}
